#ifndef MYBUTTON_H
#define MYBUTTON_H

#include <QWidget>

namespace Ui {
class myButton;
}

class myButton : public QWidget
{
    Q_OBJECT

public:
    explicit myButton(QWidget *parent = nullptr);
    ~myButton();
    void paintEvent(QPaintEvent *event);
    void mouseReleaseEvent(QMouseEvent *event);
    void mousePressEvent(QMouseEvent *event);
    void mouseDoubleClickEvent(QMouseEvent *event);
    void enterEvent(QEvent *event);
    void leaveEvent(QEvent *event);
    void setHR(QString pr);
    void setUserID(QString userID,QString userName);
    void setOx(QString ox);
    void setPidian(QString pd);
    void setMp(QString Mp);

    void setColor(int eleoff);
private:
    Ui::myButton *ui;
    int mouseFlag=0;
    int iseleoff;
signals:
    void Clicked();
};

#endif // MYBUTTON_H
